#ifndef DDAS_CLIENT_IO_H
#define DDAS_CLIENT_IO_H

#include <iostream>

#include <xercesc/util/XMLString.hpp>

#include "lip.h"

#include "ddas_results.h"

#define RESULT_FILE "result"
#define STATE_FILE "state"
#define SERIALIZATION_SUCCESS 1
#define SERIALIZATION_FAILURE 0

using namespace std;

//INIT
int init_vars_from_scoping_file(string resolved_name, verylong* start , verylong* end, int* numberResults, int* numberRows, int* numberX, int* numberY );
int init_vars_from_state_file( string file_name, verylong* i );

//INPUT
void ddas_parse_scoping_file();
void ddas_parse_data_file();
int ddas_parse_state_file( verylong* i );

//OUTPUT
int ddas_write_results_to_file(DDAS_CLIENT_RESULT_SET*);
int ddas_write_state_to_file(verylong i);

//DELETION
int ddas_delete_state_file();

#endif